﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
					xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
					xmlns:mwt="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"
					xmlns:Control="clr-namespace:Opds_Viewer.Control"
					xmlns:local="clr-namespace:Opds_Viewer"
					xmlns:shell="clr-namespace:Microsoft.Windows.Shell;assembly=Microsoft.Windows.Shell"
					xmlns:cmd="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WPF4"
					xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
                    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:Opds_Viewer_Converter="clr-namespace:Opds_Viewer.Converter" mc:Ignorable="d">
	<Opds_Viewer_Converter:NbBooksConverter x:Key="NbBooksConverter"/>

	<Opds_Viewer_Converter:BoolToVisibilityConverter x:Key="BoolToVisibilityConverter"/>

	<!--***********************************************************
	* REGION : Main Window
	************************************************************-->
	
	<ControlTemplate x:Key="MainWindowControlTemplate" TargetType="{x:Type local:MainWindow}">
		<Border Background="{DynamicResource MainWindowBackground}" BorderBrush="{DynamicResource MainColorApplication}" BorderThickness="2">
			<Grid>
				<Grid.RowDefinitions>
					<RowDefinition Height="30" />
					<RowDefinition Height="*"/>
				</Grid.RowDefinitions>

				<!-- Captions Buttons to control the window borderless-->
				<Control:CaptionButtons Margin="0,0,10,0" Grid.Row="0" HorizontalAlignment="Right" Type="Full"
										Foreground="{DynamicResource CaptionButtonColor}" FontSize="14" MarginButton="0,0,5,0"
										VerticalAlignment="Center" shell:WindowChrome.IsHitTestVisibleInChrome="True" Panel.ZIndex="10"/>

				<ContentPresenter Margin="6" Grid.Row="1" Content="{TemplateBinding Content}"/>
			</Grid>
		</Border>
	</ControlTemplate>

	<Style x:Key="MainWindowStyle" TargetType="{x:Type local:MainWindow}">
		<Setter Property="shell:WindowChrome.WindowChrome">
			<Setter.Value>
				<shell:WindowChrome
						ResizeBorderThickness="6"
						CaptionHeight="30"
						CornerRadius="0"
						GlassFrameThickness="0"/>
			</Setter.Value>
		</Setter>
		<Setter Property="Template" Value="{DynamicResource MainWindowControlTemplate}"/>
	</Style>

	<!--***********************************************************
	* REGION : Vertical & horizontal scrollbar
	************************************************************-->

	<ControlTemplate x:Key="HorizontalScrollBarTemplate" TargetType="{x:Type ScrollBar}">
		<Grid x:Name="Root">
			<Grid.Resources>
				<ControlTemplate x:Key="RepeatButtonTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root" Background="Transparent">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="HorizontalIncrementTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="HoverPath">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Blur">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard/>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Root">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Path Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z " Height="6" Stretch="Uniform" Width="4" Fill="{DynamicResource ScrollButtonBrush}"/>
						<Path x:Name="HoverPath" Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z " Height="6" Stretch="Uniform" Width="4" UseLayoutRounding="False" Opacity="0" Margin="1,1,0,0" Fill="{DynamicResource ScrollButtonHoverBrush}"/>
						<Path x:Name="Blur" Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z " Height="6" Stretch="Uniform" Width="4" UseLayoutRounding="False" Opacity="0" Margin="1,1,0,0" Fill="{DynamicResource ScrollButtonPressedBrush}">
							<Path.Effect>
								<BlurEffect/>
							</Path.Effect>
						</Path>
						<Rectangle x:Name="DisabledElement" Fill="{DynamicResource ScrollButtonDisabledBrush}" Opacity="0" RadiusY="2" RadiusX="2"/>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="HorizontalDecrementTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="HoverPath">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Blur">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard/>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Root">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Path Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z " Height="6" Stretch="Uniform" Width="4" Fill="{DynamicResource ScrollButtonBrush}"/>
						<Path x:Name="HoverPath" Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z " Height="6" Stretch="Uniform" Width="4" UseLayoutRounding="False" Opacity="0" Margin="0,1,0,0" Fill="{DynamicResource ScrollButtonHoverBrush}"/>
						<Path x:Name="Blur" Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z " Height="6" Stretch="Uniform" Width="4" UseLayoutRounding="False" Opacity="0" Margin="0,1,0,0" Fill="{DynamicResource ScrollButtonPressedBrush}">
							<Path.Effect>
								<BlurEffect/>
							</Path.Effect>
						</Path>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="HorizontalThumbTemplate" TargetType="{x:Type Thumb}">
					<Grid>
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="MouseOverRectangle">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="PressedRectangle">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="ThumbVisual">
											<SplineDoubleKeyFrame KeyTime="0:0:0" Value="0"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Grid x:Name="ThumbVisual" Margin="0,1,0,1">
							<Rectangle x:Name="Background" StrokeThickness="1" Fill="{DynamicResource ScrollThumbBrush}" />
							<Rectangle x:Name="MouseOverRectangle" StrokeThickness="1" Opacity="0" Fill="{DynamicResource ScrollThumbBrush}" />
							<Rectangle x:Name="PressedRectangle" StrokeThickness="1" Opacity="0" Fill="{DynamicResource ScrollThumbBrush}" />
						</Grid>
					</Grid>
				</ControlTemplate>
			</Grid.Resources>
			<VisualStateManager.VisualStateGroups>
				<VisualStateGroup x:Name="CommonStates">
					<VisualState x:Name="Normal"/>
					<VisualState x:Name="MouseOver"/>
					<VisualState x:Name="Disabled">
						<Storyboard>
							<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Root">
								<SplineDoubleKeyFrame KeyTime="0" Value="0.5"/>
							</DoubleAnimationUsingKeyFrames>
						</Storyboard>
					</VisualState>
				</VisualStateGroup>
			</VisualStateManager.VisualStateGroups>
			<Grid x:Name="HorizontalRoot" Height="11">
				<Grid.ColumnDefinitions>
					<ColumnDefinition Width="Auto"/>
					<ColumnDefinition Width="*"/>
					<ColumnDefinition Width="Auto"/>
				</Grid.ColumnDefinitions>

				<Border BorderThickness="0,0,0,1" Grid.RowSpan="1" Margin="0,0,0,-1" Grid.ColumnSpan="3" BorderBrush="{DynamicResource ScrollButtonBrush}"/>

				<RepeatButton x:Name="HorizontalSmallDecrease" 
								  Grid.Column="0" 
								  Interval="50"
								  IsTabStop="False" 
								  Width="16" Margin="1"
								  Template="{StaticResource HorizontalDecrementTemplate}" 
								  Command="ScrollBar.LineLeftCommand"
								  Visibility="{Binding Visibility, ElementName=PART_Track}" />

				<Track x:Name="PART_Track" Grid.Column="1" Orientation="Horizontal">
					<Track.DecreaseRepeatButton>
						<RepeatButton x:Name="HorizontalLargeDecrease" IsTabStop="False" Interval="50" Template="{StaticResource RepeatButtonTemplate}" Command="ScrollBar.PageLeftCommand" />
					</Track.DecreaseRepeatButton>
					<Track.Thumb>
						<Thumb x:Name="HorizontalThumb" Background="{TemplateBinding Background}" Grid.Column="2" MinWidth="18" Template="{StaticResource HorizontalThumbTemplate}" Width="18" HorizontalAlignment="Stretch" />
					</Track.Thumb>
					<Track.IncreaseRepeatButton>
						<RepeatButton x:Name="HorizontalLargeIncrease" IsTabStop="False" Interval="50" Template="{StaticResource RepeatButtonTemplate}" Command="ScrollBar.PageRightCommand"/>
					</Track.IncreaseRepeatButton>
				</Track>

				<RepeatButton x:Name="HorizontalSmallIncrease" 
								  Grid.Column="2" 
								  IsTabStop="False" 
								  Interval="50"
								  Width="16" Margin="1" 
								  Template="{StaticResource HorizontalIncrementTemplate}" 
								  Command="ScrollBar.LineRightCommand"
								  Visibility="{Binding Visibility, ElementName=PART_Track}" />
			</Grid>
		</Grid>
	</ControlTemplate>

	<ControlTemplate x:Key="VerticalScrollBarTemplate" TargetType="{x:Type ScrollBar}">
		<Grid x:Name="Root">
			<Grid.Resources>
				<ControlTemplate x:Key="RepeatButtonTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root" Background="Transparent">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="VerticalIncrementTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="HoverPath">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Blur">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard/>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Root">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Path Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " Height="4" Stretch="Uniform" Width="6" Fill="{DynamicResource ScrollButtonBrush}"/>
						<Path x:Name="HoverPath" Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " Height="4" Stretch="Uniform" Width="6" UseLayoutRounding="False" Opacity="0" Margin="1,0,0,0" Fill="{DynamicResource ScrollButtonHoverBrush}"/>
						<Path x:Name="Blur" Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " Height="4" Stretch="Uniform" Width="6" UseLayoutRounding="False" Opacity="0" Margin="1,0,0,0" Fill="{DynamicResource ScrollButtonPressedBrush}">
							<Path.Effect>
								<BlurEffect/>
							</Path.Effect>
						</Path>
						<Rectangle x:Name="DisabledElement" Fill="{DynamicResource ScrollButtonDisabledBrush}" Opacity="0" RadiusY="2" RadiusX="2"/>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="VerticalDecrementTemplate" TargetType="{x:Type RepeatButton}">
					<Grid x:Name="Root">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="HoverPath">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Blur">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard/>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Root">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Rectangle x:Name="Background" Fill="{DynamicResource ScrollBackgroundBrush}" Opacity="0" RadiusY="2" RadiusX="2" StrokeThickness="1"/>
						<Rectangle x:Name="BackgroundMouseOver" Fill="{DynamicResource ScrollBackgroundBrush}" Opacity="0" RadiusY="2" RadiusX="2" />
						<Rectangle x:Name="BackgroundPressed" Fill="{DynamicResource ScrollBackgroundBrush}" Opacity="0" RadiusY="2" RadiusX="2" />
						<Rectangle x:Name="BackgroundGradient" Fill="{DynamicResource ScrollBackgroundBrush}" Margin="1" Opacity="0" RadiusY="1" RadiusX="1" Stroke="{DynamicResource ScrollBackgroundBrush}" StrokeThickness="1"/>
						<Rectangle x:Name="Highlight" IsHitTestVisible="false" Margin="1" Opacity="0" RadiusY="1" RadiusX="1" Stroke="{DynamicResource ScrollBackgroundBrush}" StrokeThickness="1"/>
						<Path Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " Height="4" Stretch="Uniform" Width="6" Fill="{DynamicResource ScrollButtonBrush}"/>
						<Path x:Name="HoverPath" Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " Height="4" Stretch="Uniform" Width="6" UseLayoutRounding="False" Opacity="0" Margin="1,0,0,0" Fill="{DynamicResource ScrollButtonHoverBrush}"/>
						<Path x:Name="Blur" Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " Height="4" Stretch="Uniform" Width="6" UseLayoutRounding="False" Opacity="0" Margin="1,0,0,0" Fill="{DynamicResource ScrollButtonPressedBrush}">
							<Path.Effect>
								<BlurEffect/>
							</Path.Effect>
						</Path>
					</Grid>
				</ControlTemplate>
				<ControlTemplate x:Key="VerticalThumbTemplate" TargetType="{x:Type Thumb}">
					<Grid>
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="MouseOverRectangle">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>

									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="PressedRectangle">
											<EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="1"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="ThumbVisual">
											<SplineDoubleKeyFrame KeyTime="0:0:0" Value="0"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Grid x:Name="ThumbVisual" Margin="1,0,1,0">
							<Rectangle x:Name="Background" StrokeThickness="1" Fill="{DynamicResource ScrollThumbBrush}" />
							<Rectangle x:Name="MouseOverRectangle" StrokeThickness="1" Opacity="0" Fill="{DynamicResource ScrollThumbBrush}" />
							<Rectangle x:Name="PressedRectangle" StrokeThickness="1" Opacity="0" Fill="{DynamicResource ScrollThumbBrush}" />
						</Grid>
					</Grid>
				</ControlTemplate>
			</Grid.Resources>
			<VisualStateManager.VisualStateGroups>
				<VisualStateGroup x:Name="CommonStates">
					<VisualState x:Name="Normal"/>
					<VisualState x:Name="MouseOver"/>
					<VisualState x:Name="Disabled">
						<Storyboard>
							<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Root">
								<SplineDoubleKeyFrame KeyTime="0" Value="0.5"/>
							</DoubleAnimationUsingKeyFrames>
						</Storyboard>
					</VisualState>
				</VisualStateGroup>
			</VisualStateManager.VisualStateGroups>
			<Grid x:Name="VerticalRoot" Width="11">
				<Grid.RowDefinitions>
					<RowDefinition Height="Auto"/>
					<RowDefinition Height="*"/>
					<RowDefinition Height="Auto"/>
				</Grid.RowDefinitions>

				<Border BorderThickness="0,0,1,0" Margin="0,0,-1,0" Grid.RowSpan="3" BorderBrush="{DynamicResource ScrollButtonBrush}"/>

				<RepeatButton x:Name="VerticalSmallDecrease" 
								  Grid.Row="0" 
								  IsTabStop="False" 
								  Interval="50"
								  Height="16" Margin="1" 
								  Template="{StaticResource VerticalDecrementTemplate}" 
								  Command="ScrollBar.LineUpCommand" 
								  Visibility="{Binding Visibility, ElementName=PART_Track}" />

				<Track x:Name="PART_Track" Grid.Row="1" IsDirectionReversed="True" Orientation="Vertical">
					<Track.DecreaseRepeatButton>
						<RepeatButton x:Name="VerticalLargeDecrease" Interval="50" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" Command="ScrollBar.PageUpCommand" />
					</Track.DecreaseRepeatButton>
					<Track.Thumb>
						<Thumb x:Name="VerticalThumb" Height="Auto" MinHeight="18" Template="{StaticResource VerticalThumbTemplate}" VerticalAlignment="Stretch" />
					</Track.Thumb>
					<Track.IncreaseRepeatButton>
						<RepeatButton x:Name="VerticalLargeIncrease" IsTabStop="False" Interval="50" Template="{StaticResource RepeatButtonTemplate}" Command="ScrollBar.PageDownCommand"/>
					</Track.IncreaseRepeatButton>
				</Track>

				<RepeatButton x:Name="VerticalSmallIncrease" 
								  Grid.Row="2" 
								  IsTabStop="False" 
								  Interval="50"
								  Height="16" Margin="1" 
								  Template="{StaticResource VerticalIncrementTemplate}" 
								  Command="ScrollBar.LineDownCommand"
								  Visibility="{Binding Visibility, ElementName=PART_Track}" />
			</Grid>
		</Grid>
	</ControlTemplate>

	<Style x:Key="{x:Type ScrollBar}" TargetType="{x:Type ScrollBar}">
		<Setter Property="OverridesDefaultStyle" Value="True"/>
		<Setter Property="SnapsToDevicePixels" Value="True"/>
		<Setter Property="MinWidth" Value="20"/>
		<Setter Property="MinHeight" Value="20"/>
		<Setter Property="IsTabStop" Value="False"/>
		<Style.Triggers>
			<Trigger Property="Orientation" Value="Horizontal">
				<Setter Property="Width" Value="Auto" />
				<Setter Property="Template" Value="{StaticResource HorizontalScrollBarTemplate}" />
			</Trigger>
			<Trigger Property="Orientation" Value="Vertical">
				<Setter Property="Height" Value="Auto" />
				<Setter Property="Template" Value="{StaticResource VerticalScrollBarTemplate}" />
			</Trigger>
		</Style.Triggers>
	</Style>

	<!--***********************************************************
	* REGION : Menu
	************************************************************-->
	
	<Style x:Key="Menu" TargetType="{x:Type Menu}">
		<Setter Property="Background" Value="{DynamicResource MenuBackgroundBrush}"/>
		<Setter Property="BorderBrush" Value="{DynamicResource MenuBackgroundBrush}"/>
		<Setter Property="SnapsToDevicePixels" Value="True"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Menu}">
					<Grid>
						<Border Margin="0" x:Name="Border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"/>
						<StackPanel Background="{TemplateBinding Background}" IsItemsHost="True" ClipToBounds="True" Orientation="Horizontal"/>
					</Grid>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style x:Key="MenuItem" TargetType="{x:Type MenuItem}">
		<Setter Property="HorizontalContentAlignment" Value="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
		<Setter Property="VerticalContentAlignment" Value="{Binding VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
		<Setter Property="Background" Value="Transparent"/>
		<Setter Property="Width" Value="80"/>
		<Setter Property="Foreground" Value="{DynamicResource MenuNormalText}"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type MenuItem}">
					<Border x:Name="Border" Background="{TemplateBinding Background}"
							BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
						<Grid>
							<ContentPresenter Margin="{TemplateBinding Padding}" x:Name="HeaderHost" RecognizesAccessKey="True" ContentSource="Header"/>
						</Grid>
					</Border>
					<ControlTemplate.Triggers>
						<Trigger Property="IsHighlighted" Value="true">
							<Setter Property="Background" Value="{DynamicResource MenuHighlightedBackgroundBrush}" TargetName="Border"/>
							<Setter Property="Foreground" Value="{DynamicResource MenuHighlightedText}"/>
						</Trigger>
						<Trigger Property="IsChecked" Value="true">
							<Setter Property="Background" Value="{DynamicResource MenuHighlightedBackgroundBrush}" TargetName="Border"/>
							<Setter Property="Foreground" Value="{DynamicResource MenuHighlightedText}"/>
						</Trigger>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style x:Key="MenuSeparator" TargetType="{x:Type Separator}">
		<Setter Property="Height" Value="Auto"/>
		<Setter Property="Margin" Value="0"/>
		<Setter Property="Focusable" Value="false"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Separator}">
					<Border BorderBrush="{DynamicResource MenuHighlightedBackgroundBrush}" BorderThickness="0.5"/>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<!--***********************************************************
	* REGION : Buttons & SplitButton
	************************************************************-->

	<Style TargetType="{x:Type Control:SplitButton}" BasedOn="{StaticResource {x:Type Button}}">
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Control:SplitButton}">
					<mwt:ButtonChrome x:Name="Chrome" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" RenderDefaulted="{TemplateBinding IsDefaulted}" RenderMouseOver="{TemplateBinding IsMouseOver}" RenderPressed="{TemplateBinding IsPressed}" SnapsToDevicePixels="True">
						<Grid>
							<Grid.ColumnDefinitions>
								<ColumnDefinition/>
								<ColumnDefinition Width="Auto"/>
								<ColumnDefinition Width="Auto"/>
							</Grid.ColumnDefinitions>
							<ContentPresenter Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" ContentTemplate="{TemplateBinding ContentTemplate}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
							<Rectangle Grid.Column="1" Width="1" Fill="{TemplateBinding Foreground}" Opacity="0.4" Margin="0 4 0 4"/>
							<Grid x:Name="SplitElement" Grid.Column="2" Background="Transparent">
								<ContextMenuService.ContextMenu>
									<ContextMenu ItemContainerStyle="{Binding ButtonMenuItemsContainerStyle, RelativeSource={RelativeSource TemplatedParent}}"
												 ItemTemplate="{Binding ButtonMenuItemsTemplate, RelativeSource={RelativeSource TemplatedParent}}"
												 ItemsSource="{Binding ButtonMenuItemsSource, RelativeSource={RelativeSource TemplatedParent}}"
												 Foreground="{TemplateBinding Foreground}" FlowDirection="{TemplateBinding FlowDirection}"/>
								</ContextMenuService.ContextMenu>
								<Path Data="M 0,0 L 8,0 L 4,4 Z" Fill="{TemplateBinding Foreground}" Margin="2 0 4 0" VerticalAlignment="Center"/>
							</Grid>
						</Grid>
					</mwt:ButtonChrome>
					<ControlTemplate.Triggers>
						<Trigger Property="IsKeyboardFocused" Value="True">
							<Setter Property="RenderDefaulted" TargetName="Chrome" Value="True" />
						</Trigger>
						<Trigger Property="ToggleButton.IsChecked" Value="True">
							<Setter Property="RenderPressed" TargetName="Chrome" Value="True" />
						</Trigger>
						<Trigger Property="IsEnabled" Value="False">
							<Setter Property="Foreground" Value="#FFADADAD" />
						</Trigger>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style x:Key="SimpleButtonFocusVisual">
		<Setter Property="Control.Template">
			<Setter.Value>
				<ControlTemplate>
					<Border>
						<Rectangle Margin="2" Stroke="#60000000" StrokeThickness="1" StrokeDashArray="1 2"/>
					</Border>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>
	
	<ControlTemplate x:Key="WhiteButtonControlTemplate" TargetType="{x:Type Button}">
		<Grid x:Name="Grid">
			<Border x:Name="Border" Background="{TemplateBinding Background}"
                    BorderBrush="{TemplateBinding BorderBrush}"
                    BorderThickness="{TemplateBinding BorderThickness}"
                    Padding="{TemplateBinding Padding}" CornerRadius="6"/>

			<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True"/>
		</Grid>
        
		<ControlTemplate.Triggers>
			<Trigger Property="IsKeyboardFocused" Value="true">
				<Setter Property="BorderBrush" Value="{DynamicResource DefaultButtonBorderBrush}" TargetName="Border"/>
			</Trigger>
			<Trigger Property="IsMouseOver" Value="true">
                <Setter Property="Background" Value="{DynamicResource MouseOverButtonBrush}" TargetName="Border"/>
                <Setter Property="Foreground" Value="{DynamicResource OverButtonForegroundBrush}"/>
            </Trigger>
			<Trigger Property="IsPressed" Value="true">
				<Setter Property="Background" Value="{DynamicResource PressedButtonBrush}" TargetName="Border"/>
                <Setter Property="BorderBrush" Value="{DynamicResource PressedButtonBorderBrush}" TargetName="Border"/>
                <Setter Property="Foreground" Value="{DynamicResource OverButtonForegroundBrush}"/>
            </Trigger>
			<Trigger Property="IsEnabled" Value="true"/>
			<Trigger Property="IsEnabled" Value="false">
				<Setter Property="Background" Value="{DynamicResource DisabledButtonBackgroundBrush}" TargetName="Border"/>
				<Setter Property="BorderBrush" Value="{DynamicResource DisabledButtonBorderBrush}" TargetName="Border"/>
				<Setter Property="Foreground" Value="{DynamicResource DisabledButtonForegroundBrush}"/>
			</Trigger>
		</ControlTemplate.Triggers>
	</ControlTemplate>

	<Style x:Key="WhiteButton" TargetType="{x:Type Button}" BasedOn="{x:Null}">
		<Setter Property="FocusVisualStyle" Value="{DynamicResource SimpleButtonFocusVisual}"/>
		<Setter Property="Background" Value="{DynamicResource MainWindowBackground}"/>
		<Setter Property="BorderBrush" Value="{DynamicResource DefaultButtonBorderBrush}"/>
		<Setter Property="Template" Value="{DynamicResource WhiteButtonControlTemplate}"/>
		<Setter Property="Foreground" Value="{DynamicResource ContentTextColor}"/>
		<Setter Property="BorderThickness" Value="2"/>
		<Setter Property="Width" Value="100"/>
		<Setter Property="FontFamily" Value="Verdana"/>
		<Setter Property="FontSize" Value="14.667"/>
	</Style>

	<!--***********************************************************
	* REGION : CheckBox
	************************************************************-->
		
	<Style x:Key="EmptyCheckBoxFocusVisual">
		<Setter Property="Control.Template">
			<Setter.Value>
				<ControlTemplate>
					<Rectangle Margin="1" SnapsToDevicePixels="true" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" StrokeThickness="1" StrokeDashArray="1 2"/>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style x:Key="CheckRadioFocusVisual">
		<Setter Property="Control.Template">
			<Setter.Value>
				<ControlTemplate>
					<Rectangle Margin="14,0,0,0" SnapsToDevicePixels="true" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" StrokeThickness="1" StrokeDashArray="1 2"/>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style x:Key="CheckBoxStyle" TargetType="{x:Type CheckBox}">
		<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
		<Setter Property="Background" Value="{StaticResource CheckBoxFillNormal}"/>
		<Setter Property="BorderBrush" Value="{StaticResource CheckBoxStroke}"/>
		<Setter Property="BorderThickness" Value="1"/>
		<Setter Property="FocusVisualStyle" Value="{StaticResource EmptyCheckBoxFocusVisual}"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type CheckBox}">
					<BulletDecorator Background="Transparent">
						<BulletDecorator.Bullet>
							<Border x:Name="Border"
									Width="13"
									Height="13"
									CornerRadius="0"
									BorderThickness="1">
								<Border.BorderBrush>
									<LinearGradientBrush StartPoint="0,0"
										EndPoint="0,1">
										<LinearGradientBrush.GradientStops>
											<GradientStopCollection>
												<GradientStop Color="{DynamicResource BorderLightColor}" Offset="0.0" />
												<GradientStop Color="{DynamicResource BorderDarkColor}" Offset="1.0" />
											</GradientStopCollection>
										</LinearGradientBrush.GradientStops>
									</LinearGradientBrush>
								</Border.BorderBrush>
								<Border.Background>
									<LinearGradientBrush StartPoint="0,0"
										EndPoint="0,1">
										<LinearGradientBrush.GradientStops>
											<GradientStopCollection>
												<GradientStop Color="{DynamicResource ControlLightColor}" />
												<GradientStop Color="{DynamicResource ControlMediumColor}" Offset="1.0" />
											</GradientStopCollection>
										</LinearGradientBrush.GradientStops>
									</LinearGradientBrush>

								</Border.Background>
								<Grid>
									<Path Visibility="Collapsed"
										Width="7"
										Height="7"
										x:Name="CheckMark"
										SnapsToDevicePixels="False"
										StrokeThickness="2"
										Data="M 0 0 L 7 7 M 0 7 L 7 0">
											<Path.Stroke>
												<SolidColorBrush Color="{DynamicResource GlyphColor}" />
											</Path.Stroke>
									</Path>
									<Path Visibility="Collapsed"
										  Width="7"
										  Height="7"
										  x:Name="InderminateMark"
										  SnapsToDevicePixels="False"
										  StrokeThickness="2"
										  Data="M 0 7 L 7 0">
										<Path.Stroke>
											<SolidColorBrush Color="{DynamicResource GlyphColor}" />
										</Path.Stroke>
									</Path>
								</Grid>
							</Border>
						</BulletDecorator.Bullet>
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualState x:Name="Normal" />
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border"
												Storyboard.TargetProperty="(Panel.Background).        (GradientBrush.GradientStops)[1].(GradientStop.Color)">
											<EasingColorKeyFrame KeyTime="0"
										 Value="{DynamicResource ControlMouseOverColor}" />
										</ColorAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard>
										<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border"
												Storyboard.TargetProperty="(Panel.Background).        (GradientBrush.GradientStops)[1].(GradientStop.Color)">
											<EasingColorKeyFrame KeyTime="0"
										 Value="{DynamicResource ControlPressedColor}" />
										</ColorAnimationUsingKeyFrames>
										<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border"
												Storyboard.TargetProperty="(Border.BorderBrush).        (GradientBrush.GradientStops)[0].(GradientStop.Color)">
											<EasingColorKeyFrame KeyTime="0"
										 Value="{DynamicResource PressedBorderDarkColor}" />
										</ColorAnimationUsingKeyFrames>
										<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border"
												Storyboard.TargetProperty="(Border.BorderBrush).        (GradientBrush.GradientStops)[1].(GradientStop.Color)">
											<EasingColorKeyFrame KeyTime="0"
										 Value="{DynamicResource PressedBorderLightColor}" />
										</ColorAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Disabled" />
							</VisualStateGroup>
							<VisualStateGroup x:Name="CheckStates">
								<VisualState x:Name="Checked">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)"
												 Storyboard.TargetName="CheckMark">
											<DiscreteObjectKeyFrame KeyTime="0"
											Value="{x:Static Visibility.Visible}" />
										</ObjectAnimationUsingKeyFrames>
										<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="Border">
											<EasingColorKeyFrame KeyTime="0" Value="{StaticResource BorderMediumColor}"/>
										</ColorAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Offset)" Storyboard.TargetName="Border">
											<EasingDoubleKeyFrame KeyTime="0" Value="0.569"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Unchecked" />
								<VisualState x:Name="Indeterminate">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)"
												 Storyboard.TargetName="InderminateMark">
											<DiscreteObjectKeyFrame KeyTime="0"
											Value="{x:Static Visibility.Visible}" />
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<ContentPresenter Margin="4,0,0,0"
							VerticalAlignment="Center"
							HorizontalAlignment="Left"
							RecognizesAccessKey="True" />
					</BulletDecorator>
					<ControlTemplate.Triggers>
						<Trigger Property="HasContent" Value="true">
							<Setter Property="FocusVisualStyle" Value="{StaticResource CheckRadioFocusVisual}"/>
							<Setter Property="Padding" Value="4,0,0,0"/>
						</Trigger>
						<Trigger Property="IsEnabled" Value="false">
							<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
						</Trigger>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<!--***********************************************************
	* REGION : CatalogView
	************************************************************-->
	
	<Style x:Key="FormatStyle" TargetType="{x:Type MenuItem}">
		<Setter Property="Command" Value="{Binding DataContext.MarkDownloadCommand, RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}" />
		<Setter Property="CommandParameter" Value="{Binding Format}" />
		<Setter Property="StaysOpenOnClick" Value="True" />
		<Setter Property="HeaderTemplate">
			<Setter.Value>
				<DataTemplate>
					<Grid>
						<Grid.ColumnDefinitions>
							<ColumnDefinition Width="Auto" />
							<ColumnDefinition Width="*" />
						</Grid.ColumnDefinitions>
						<!--<Image Grid.Column="0" Margin="-30,0,5,0" Source="../Resources/Images/tick.png" Visibility="{Binding Download, Converter={StaticResource BoolToVisibilityConverter}}" />-->
						<CheckBox Grid.Column="0" Margin="-30,0,5,0" IsChecked="{Binding Download, Mode=TwoWay}" />
						<TextBlock Grid.Column="1" Text="{Binding Format}" VerticalAlignment="Center" />
					</Grid>
				</DataTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<DataTemplate x:Key="ListEbookItemTemplate">
		<StackPanel Orientation="Horizontal">
			<CheckBox IsChecked="{Binding Download, Mode=TwoWay}" VerticalAlignment="Center" BorderThickness="1" Margin="5,0" Style="{DynamicResource CheckBoxStyle}" Visibility="Collapsed">
				<i:Interaction.Triggers>
					<i:EventTrigger EventName="Checked">
						<cmd:EventToCommand Command="{Binding DataContext.MarkBookDownloadCommand, RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}" CommandParameter="{Binding}" />
					</i:EventTrigger>
				</i:Interaction.Triggers>   
			</CheckBox>
			<TextBlock Text="{Binding Title}" VerticalAlignment="Center"/>
		</StackPanel>
	</DataTemplate>
	
	<DataTemplate x:Key="CatalogDataTemplate">
		<Border x:Name="CatalogBorder">
			<StackPanel Orientation="Horizontal">
				<TextBlock x:Name="CatalogName" Height="Auto" TextWrapping="Wrap" Text="{Binding Name}" Width="Auto" VerticalAlignment="Center"/>
				<TextBlock x:Name="NbBooks" Height="Auto" TextWrapping="Wrap" Text="{Binding NbBooks, Converter={StaticResource NbBooksConverter}}" Width="Auto" Margin="50,0,0,0" FontStyle="Italic" VerticalAlignment="Center" Visibility="{Binding Status, Converter={StaticResource BoolToVisibilityConverter}}"/>
			</StackPanel>
		</Border>
	</DataTemplate>

    <Style TargetType="{x:Type ListBoxItem}">
		<Setter Property="Template">
			<Setter.Value>
                <ControlTemplate TargetType="ListBoxItem">
                    <Border x:Name="LayoutRoot" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}">
                		<VisualStateManager.VisualStateGroups>
                			<VisualStateGroup x:Name="CommonStates">
                				<VisualState x:Name="Normal"/> 
                                <VisualState x:Name="MouseOver"/>
                                <VisualState x:Name="Disabled">
                					<Storyboard>
                						<ColorAnimation Duration="0" To="Gray" Storyboard.TargetProperty="(Control.Background).(SolidColorBrush.Color)" d:IsOptimized="True"/>
                					</Storyboard>
                				</VisualState>
                			</VisualStateGroup>
                			<VisualStateGroup x:Name="SelectionStates">
                				<VisualState x:Name="Unselected"/>                                   
                				<VisualState x:Name="Selected">
                					<Storyboard>
                						<ColorAnimation Duration="0" To="#F19300" Storyboard.TargetProperty="(Control.Background).(SolidColorBrush.Color)" d:IsOptimized="True"/>
                					</Storyboard>
                				</VisualState>
                				<VisualState x:Name="SelectedUnfocused"/>
                			</VisualStateGroup>
                			<VisualStateGroup x:Name="FocusStates">
                				<VisualState x:Name="Unfocused"/>
                				<VisualState x:Name="Focused"/>
                			</VisualStateGroup>
                			<VisualStateGroup x:Name="ValidationStates">
                				<VisualState x:Name="Valid"/>
                				<VisualState x:Name="InvalidFocused"/>
                				<VisualState x:Name="InvalidUnfocused"/>
                			</VisualStateGroup>
                		</VisualStateManager.VisualStateGroups>
                		<ContentControl x:Name="ContentContainer" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
						
                	</Border>
                </ControlTemplate>
            </Setter.Value>
		</Setter>
        <!--<Style.Triggers>
            <EventTrigger RoutedEvent="MouseEnter">
                <BeginStoryboard>
                    <Storyboard>
                        <ColorAnimation Storyboard.TargetProperty="Background.Color" Duration="0:0:0.3" To="#F19300"></ColorAnimation>
                    </Storyboard>
                </BeginStoryboard>
            </EventTrigger>
            <EventTrigger RoutedEvent="MouseLeave">
                <BeginStoryboard>
                    <Storyboard>
                        <ColorAnimation Storyboard.TargetProperty="Background.Color" Duration="0:0:0.3" To="Transparent"></ColorAnimation>
                    </Storyboard>
                </BeginStoryboard>
            </EventTrigger>
        </Style.Triggers>-->
    </Style>

</ResourceDictionary>